package models;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.OneToOne;
import javax.persistence.Table;

@Entity
@Table(name = "coordinador")
public class Coordinador extends models.Entity<Long> implements ActorColegio {
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	private Long id;
	@Column(name = "id_colegio")
	private Long idColegio;

	@JoinColumn(name = "id_persona")
	@OneToOne(cascade = CascadeType.PERSIST)
	private Persona persona;

	public Coordinador() {

	}

	@Override
	public Long getIdColegio() {
		return idColegio;
	}

	@Override
	public void setIdColegio(Long idColegio) {
		this.idColegio = idColegio;
	}

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public Persona getPersona() {
		return persona;
	}

	public void setPersona(Persona persona) {
		this.persona = persona;
	}

}
